package com.tech.koufu.model;

import org.json.JSONException;
import org.json.JSONObject;

public class MarketStock {
	public String stock_code;
	public String stock_name;
	public String old_price;
	public String new_price;
	public String stock_type;
	public String zqlb;
	public String inZixuangu;
	
	public MarketStock(JSONObject obj){
		
		try {
			this.stock_code = obj.getString("stock_code");
			this.stock_name = obj.getString("stock_name");
			this.old_price = obj.getString("old_price");
			this.new_price = obj.getString("new_price");
			this.stock_type = obj.getString("stock_type");
			this.zqlb = obj.getString("zqlb");
			if(obj.has("inZixuangu")){
				this.inZixuangu = obj.getString("inZixuangu");
			}
		} catch (JSONException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
	}
}
